package com.huashi.dealer.commonEntity;

import com.baomidou.mybatisplus.annotation.*;
import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Getter;
import lombok.Setter;

import java.time.LocalDateTime;

/**
 * 退货地址实体类
 */
@Getter
@Setter
@Schema(description = "退货地址实体")
public class ReturnAddress {

    @TableId(value = "address_id", type = IdType.AUTO)
    @Schema(description = "地址ID")
    private Long addressId;

    @TableField("name")
    @Schema(description = "收货人姓名")
    private String name;

    @TableField("phone")
    @Schema(description = "收货人电话")
    private String phone;

    @TableField("province_id")
    @Schema(description = "省份ID")
    private Integer provinceId;

    @TableField("city_id")
    @Schema(description = "城市ID")
    private Integer cityId;

    @TableField("region_id")
    @Schema(description = "区县ID")
    private Integer regionId;

    @TableField("detail")
    @Schema(description = "详细地址")
    private String detail;

    @TableField("is_delete")
    @TableLogic
    @Schema(description = "软删除标记")
    private Integer isDelete;

    @TableField("create_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Schema(description = "创建时间")
    private LocalDateTime createTime;

    @TableField("update_time")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @Schema(description = "更新时间")
    private LocalDateTime updateTime;
} 